package com.work.aop.aspect;

import lombok.extern.slf4j.Slf4j;
import org.aspectj.lang.ProceedingJoinPoint;
import org.aspectj.lang.annotation.Around;
import org.aspectj.lang.annotation.Aspect;
import org.springframework.stereotype.Component;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User:DELL
 * Date:2025-06-10
 * Time:19:37
 */
@Slf4j
@Component
@Aspect
public class MyAspectDemo {
    @Around("@annotation(com.work.aop.config.MyAspect)")
    public Object doAround(ProceedingJoinPoint joinPoint) throws Throwable {
        log.info("do around before..");
        Object o=joinPoint.proceed();
        log.info("do around after..");
        return o;
    }
}
